package com.enation.app.web.tag;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.enation.app.web.core.model.Address;
import com.enation.app.web.core.service.IAddressManager;
import com.enation.framework.taglib.BaseFreeMarkerTag;

import freemarker.template.TemplateModelException;

/**
 * 
 * @function 获取省份标签
 * @author 闯哥
 * @time 2016年12月25日 上午10:38:02
 */
@Component
public class AdressProvinceTag extends BaseFreeMarkerTag {

	@Autowired
	private IAddressManager addressManager;

	@Override
	protected Object exec(Map params) throws TemplateModelException {

		List<Address> addresses = this.addressManager.getProvince();
		return addresses;
	}

}
